package com.hcbd.tdwt.base.other;

import android.text.InputFilter;
import android.text.Spanned;
import android.util.Log;

public class CustomInputFilter implements InputFilter {

    private String TAG = "CodeModeInputFilter";
    // a as asd asdf
    @Override
    public CharSequence filter(CharSequence source, int start, int end, Spanned dest, int dstart, int dend) {
//        // 允许的字符范围（A-F、a-f、0-9）
        // 检查输入的字符是否在允许范围内
        Log.e(TAG, "source: "+source+" start:"+start+" end:"+end+" dest:"+dest+" dstart:"+dstart+" dend:"+dend);
        return null;
    }

    public interface OnFilterWork{
        void onIllegalInput();
    }
    private OnFilterWork onFilterWork;
    public void setOnFilterWork(OnFilterWork onFilterWork){this.onFilterWork=onFilterWork;}
}
